<html lang="en" xmlns="http://www.w3.org/1999/xhtml" xmlns:c="http://java.sun.com/jsp/jstl/core"
      xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:h="http://java.sun.com/jsf/html">
<ui:composition>
    <c:set var="base" value="#{request.contextPath}"/>
    <c:if test="${empty group}"><c:set var="group" value="main"/></c:if>
    <c:if test="${not empty param.debug}">
        <c:set var="debugAssets" value="${param.debug}" scope="session"/>
    </c:if>
    <c:choose>
        <c:when test="${sessionScope.debugAssets}">
            <link rel="stylesheet" type="text/css" href="${base}/webjars/bootswatch-spacelab/3.3.1+2/css/bootstrap.min.css"/>
            <link rel="stylesheet" type="text/css" href="${base}/styles/style.css"/>
            <h:outputScript library="primefaces" name="jquery/jquery.js" target="head"/>
            <script type="text/javascript" src="${base}/webjars/bootstrap/3.3.1/js/bootstrap.min.js"></script>
            <script type="text/javascript" src="${base}/webjars/jquery-cookie/1.3.1/jquery.cookie.js"></script>
            <script type="text/javascript" src="${base}/scripts/script.js"></script>
        </c:when>
        <c:otherwise>
            <link rel="stylesheet" type="text/css" href="${base}/assets/v/${applicationScope.assetsVersion}/${group}.css"/>
            <h:outputScript library="primefaces" name="jquery/jquery.js" target="head"/>
            <script type="text/javascript" src="${base}/assets/v/${applicationScope.assetsVersion}/${group}.js"></script>
        </c:otherwise>
    </c:choose>
</ui:composition>
</html>
